home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gigarom 1
/
Gigarom Macintosh Archives (Quantum Leap)(CDRM1080320)(1993).iso
/
FILES
/
QUI
/
UTI
/
Feature Flick v 1.5.sea
/
movie.r
< prev
next >
Wrap
Text File
|
1992-10-21
|
31KB
|
1,127 lines
// "movie.r"
//
// -- using "SARez" { v 3.2 }
// The new "Types.r" resource description file for System 7
// adds an unsigned integer field to each of the following.
// The added field pertains to window positioning:
//
// type 'ALRT'
// type 'DLOG'
// type 'WIND'
#define SystemSevenOrLater true
#define oldTemp true /* "Somin" so I do NOT have to specify */
/* 0x0, { wCSeed } */
/* 0, { wCReserved } */
/* for every Color Table */
/* ... but I wanna !!! So sue me !!! */
#ifndef _TYPES_
#include "Types.r"
#endif
#ifndef _MACAPPTYPES_
#include "MacAppTypes.r"
#endif
// #ifndef _VIEWTYPES_
// #include "ViewTypes.r"
// #endif
#ifndef _BALLOONTYPES.R_
#include "BalloonTypes.r"
#endif
#include "TCLTypes.r"
#ifndef _H_Commands
#include "Commands.h"
#endif
#ifndef _H_Constants
#include "Constants.h"
#define ALRT_Assert ALRT_ExceptionAbort+1
#endif
/* ----- standard TCL stuff ... ----- */
/* ALRTs & DITLs (IDs: 128, 129, 150, 151, 200, 250->253, 300),
** scroll bar CNTL (ID: 300),
** 2 Estr (resNotFound = -192, memFullErr = -108),
** MBAR (ID = 1) which the TCL uses to form the Menu Bar &
** which includes the 1st three MENUs below,
** MENUs: Apple(1), File(2), Edit(3), Font(10), Size(11), Style(12)
** the grow SICN (ID: 200),
** STRs ("Save File As:" = 150,
** "Mac OS Error Encountered" = 300,
** "of a Mac OS Error" = 301),
** STR#s (Common = 128,
** Memory Warnings = 129,
** Task Names = 130,
** Exceptions = 131,
** Dlg validation = 133)
** WINDs (Clipboard = 200,
** Starter window = 500) */
include "Starter.π.rsrc" not 'MENU'; // I'm gonna replace them below ...
/* ----- my stuff ... ----- */
include "System 7";
include "MoofSND";
include "myPICTs"; // Contains the following:
// ID = 3000 ( Color Mac )
// ID = 3001 ( IACS Logo )
// ID = 3002 ( WAP Initials )
// ID = 3003 ( QuickTime )
include "Bill (B&W)"; /* Help Manager has problems with PICTs
** in 'hfdr' resource that do NOT have
** a rect whose topLeft = (0, 0). */
include "myCursors"; /* 1) color CuRSoRs:
** a) Hand (ID = 3004)
** b) Check Mark (ID = 3005)
** c) Camera (ID = 3006)
** 2) B&W CURSors:
** a) Hand (ID = 3004)
** b) Check Mark (ID = 3005)
** c) Camera (ID = 3006)
** 3) acurs + their associated CURSors:
** a) Rotating Earth (ID = 128)
** b) DogCow (ID = 129) */
// include "Mathematica"; // It's a surprise !!!
include "QTIcons"; // ICON + cicn for CDLOGPane (ID = 500)
include "VCR Remote.rsrc"; /* ICONs + cicns for Remote Control:
** (ID = 801 -> 816) */
/* ----- Constants ----- */
#define kVersID 0 /* Finder stuff ... */
#define kTopStringID 2
#define kBottomStringID 1
#define kLocalID 0
#define kBNDL_ID 128
#define kFREF_ID 128
#define kICN_ID 128
#define mySicnRsrc 300 /* rsrc ID */
#define mySicn mySicnRsrc - 256 /* "About ..." Item Icon's # */
#define myIconRsrc 400 /* rsrc ID */
#define myIcon myIconRsrc - 256 /* "Quit" Item Icon's # */
#define myIconRsrc2 500
#define myIcon2 myIconRsrc2 - 256 /* "QuickTime" Item Icon's # */
//
#define kMAC 3000
#define kWAP 3002
#define kBragWindowID 999
#define kSystem7 777 /* ID of "System 7" PICT */
#define kMeter 111
#define kSelectFrames 3000 /* My DLOGs */
#define kGoToFrame 3001
type 'JÅ£3' { /* TYPE = Signature */
pstring;
};
/* ---------- */
type 'vers' {
byte defaultVersion = 1; /* version */
byte defaultRevision = 5; /* revision */
byte defaultRevStage = 128; /* revStage */
byte defaultBuildNbr = 2; /* buildNbr */
integer defaultLang = 0; /* languageInt */
pstring; /* abbreviated string */
align word;
pstring;
};
/////////////////////
resource 'JÅ£3' (kVersID, "Version", purgeable) {
"Feature Flick {v 1.5}"
};
resource 'BNDL' (kBNDL_ID, purgeable) {
'JÅ£3', /* Signature */
kVersID,
{
'FREF',
{
kLocalID, kICN_ID; /* Local, Actual ID(s) */
};
'ICN#',
{
kLocalID, kICN_ID;
};
};
};
resource 'FREF' (kFREF_ID, "Application", purgeable) {
'APPL',
kLocalID,
"Feature Flick"
};
resource 'ICN#' (kICN_ID, "IACS", purgeable) {
{ /* Data */
$"00000000 00000000 6040FC7E 60E0FC7E"
$"61B0C060 6318C060 6318C060 6318C060"
$"6318C060 6318C060 6318C060 6318C060"
$"63F8C07E 63F8C07E 6318C006 6318C006"
$"6318C006 6318C006 6318C006 6318C006"
$"6318C006 6318C006 6318C006 6318FC7E"
$"6318FC7E 00000000 00000000 00000000"
$"7FFFFFFE 7FFFFFFE 00000000 00000000";
/* Mask */
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF"
$"FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF";
};
};
resource 'vers' (kTopStringID, purgeable) {
defaultVersion,
defaultRevision,
defaultRevStage,
defaultBuildNbr,
defaultLang,
"©92",
"©1992 I•A•C•S Software"
};
resource 'vers' (kBottomStringID, purgeable) {
defaultVersion, defaultRevision, defaultRevStage,defaultBuildNbr, defaultLang,
"1.5",
"1.5 ... in color too, folks !!"
};
resource 'SIZE' (-1, purgeable) {
dontSaveScreen,
acceptSuspendResumeEvents,
enableOptionSwitch,
canBackground,
multiFinderAware,
backgroundAndForeground,
dontGetFrontClicks, /* ... when suspended */
ignoreChildDiedEvents,
not32BitCompatible,
isHighLevelEventAware,
onlyLocalHLEvents,
notStationeryAware,
dontUseTextEditServices,
reserved,
reserved,
reserved,
1500*1024,
1500*1024
};
/////////////////////
resource 'SICN' (mySicnRsrc, "IACS", purgeable) {
{
$"FFFF"
$"FFFF"
$"B311"
$"AD77"
$"AD77"
$"AD77"
$"AD77"
$"AD77"
$"A171"
$"AD7D"
$"AD7D"
$"AD7D"
$"AD7D"
$"AD11"
$"FFFF"
$"FFFF"
};
};
/////////////////////
resource 'cicn' (myIconRsrc, "Face", purgeable) {
// *
// ********** IconPMap **********
// *
// $00000000 /* fill long = pBaseAddr */
// unsigned bitstring[1] = 1 pRowBytes = $8000 +
// unsigned bitstring[2] = 0
$0010, /* pMapRowBytes = pixelSize * rowBytes(4) */
{ 0, 0, 32, 32 }, /* bounds */
0, /* pmVersion */
0, /* packType */
0, /* packSize */
$00480000, /* hRes */
$00480000, /* vRes */
chunky, /* pixelType */
4, /* pixelSize */
1, /* cmpCount */
4, /* cmpSize = pixelSize */
0, /* planeBytes */
0, /* pmTable */
// 00000000 /* fill long = pmReserved */
// *
// ********** IconMask **********
// *
// 00000000 /* fill long = mBaseAddr */
4, /* maskRowBytes */
{ 0, 0, 32, 32 }, /* mbounds */
// *
// ********** IconBMap **********
// *
// 00000000 /* fill long = 1BaseAddr */
4, /* iconBMapRowBytes */
{ 0, 0, 32, 32 }, /* 1bounds */
// *
// ********** IconData **********
// *
// 00000000 /* fill long = Placeholder for Handle. */
// *
// ********** MaskData **********
// *
// hex string [$$Word(maskRowBytes) * ($$BitField(Bounds, 32, 16) /*bottom*/ -
// $$BitField(Bounds, 0, 16) /*top*/ ]
$"00BFEF80 01BFBFC0 03FFFFE0 0EFFFFF0"
$"07FFFFF8 0FFFFFF0 0FFFFFF8 1FFFFFF8"
$"0FFFFFFC 3FFFFFFE 3FFFFFFE 1FFFFFFE"
$"7FFFFFFE 3FFFFFFC 7FFFFFFE 3FFFFFFE"
$"7FFFFFFE 1FFFFFFE 0FFFFFFE 1FFFFFFE"
$"0FFFFFFF 07FFFFF8 01FFFFF0 00FFFFC0"
$"00FFFEC0 00FFFFF8 01FFFFFF 03FFFFFF"
$"1FFFFFFE 7FFFFFE0 FFFFFFC0 01FFFF00",
// *
// ********** BMapData **********
// *
// hex string [$$Word(iconBMapRowBytes) * ($$BitField(Bounds, 32, 16) /*bottom*/ -
// $$BitField(Bounds, 0, 16) /*top*/ ]
$"0017C300 00BFAF80 01B7FFC0 06EFB7E0"
$"03F73AF0 07D40960 05C20330 0FA00230"
$"07800138 1D8001FC 178000DC 0F8000FC"
$"3FBA2F6C 1BBDDC88 3B566A4C 190A1D4C"
$"3C024054 0C8640BC 07742E3C 0F034034"
$"058FF87A 029BECD0 009C1CA0 0043E080"
$"0061C280 00400070 0050044E 00C80861"
$"0783E060 18800040 20C000C0 00600300",
// *
// ********** PMapCTab **********
// *
0x0, /* ictSeed */
0, /* ictFlags */
// integer = $$Countof(ColorSpec) - 1 /* ctSize */
// *
// ********** startICT **********
// *
{
0, $FFFF, $FFFF, $FFFF; /* white */
1, $FFFF, $B95B, $AD15; /* light flesh */
2, $FFFF, $8978, $70E4; /* dark flesh */
3, $DD6B, $08C2, $06A2; /* red */
4, $7EFF, $41F2, $22FD; /* brown */
5, $0000, $0000, $D400; /* blue */
6, $0000, $0000, $0000; /* black */
},
// *
// ********** endICT **********
// *
// ********** PMapData **********
// *
// hex string [$$BitField(pMapRowBytes, 0, 13) *
// ($$BitField(Bounds, 32, 16) /*bottom*/ -
// $$BitField(Bounds, 0, 16) /*top*/ ]
$"00000000 00060666 66000066 00000000"
$"00000000 60666666 60606666 60000000"
$"00000006 60660666 66666666 66000000"
$"00000660 66616666 61661666 66600000"
$"00000066 66661666 11666161 66660000"
$"00000666 66161611 11116116 16600000"
$"00000606 66111161 11111166 11660000"
$"00006666 61611111 11111161 11660000"
$"00000666 61111111 11111116 11666000"
$"00066606 61111111 11111116 66666600"
$"00060666 61111111 11111111 66166600"
$"00006666 61111111 11111111 66666600"
$"00666666 33333131 13333331 16616600"
$"00066163 41444313 34144413 61116000"
$"00666163 14141321 34414143 16116600"
$"00066113 11114321 31144413 16116600"
$"00666613 11111321 31111113 16160600"
$"00006611 33333121 13333331 61666600"
$"00000666 11111211 11111111 11666600"
$"00006666 11111122 12111111 11660600"
$"00000606 11112222 22222111 16666060"
$"00000060 11122122 22212211 66060000"
$"00000000 11122211 11122211 10600000"
$"00000000 01111122 22211111 10000000"
$"00000000 01111112 22111121 10000000"
$"00000000 02111111 11111211 55550000"
$"00000000 51121111 11112111 55555550"
$"00000005 51112111 11121111 55555550"
$"00005555 11111222 22111111 55555500"
$"00555555 55555555 55555555 55000000"
$"05555555 55555555 55555555 50000000"
$"00000000 55555555 55555550 00000000"
};
/* ---------- */
// Mac SE-&-below-version for the above:
resource 'ICON' (myIconRsrc, "Face", purgeable) {
$"0017C300 00BFAF80 01B7FFC0 06EFB7E0 03F73AF0 07D40960 05C20330 0FA00230"
$"07800138 1D8001FC 178000DC 0F8000FC 3FBA2F6C 1BBDDC88 3B566A4C 190A1D4C"
$"3C024054 0C8640BC 07742E3C 0F034034 058FF87A 029BECD0 009C1CA0 0043E080"
$"0061C280 00400070 0050044E 00C80861 0783E060 18800040 20C000C0 00600300"
};
/////////////////////
resource 'WIND' (kSystem7, "System 7", purgeable) {
{91, 206, 251, 306},
plainDBox,
visible,
nogoAway,
0x0,
"", /* NO title for this type */
centerMainScreen
};
resource 'WIND' (kBragWindowID, "Brag", purgeable) {
{60, 40, 165, 415}, // Holds the "IACS" PICT.
altDBoxProc,
invisible,
nogoAway,
0x0, /* Refcon */
"", /* NO title for this type */
centerMainScreen
};
resource 'WIND' (kWAP, "Scroll", purgeable) {
{60, 40, 165, 415}, // Holds the "WAP" PICT.
noGrowDocProc,
invisible,
nogoAway,
0x0,
"Spiffy, Ain’t It !*?*!",
centerMainScreen
};
resource 'WIND' (kMeter, "Meter", purgeable) {
{60, 40, 130, 340},
rDocProc,
invisible,
nogoAway,
0x0,
"",
centerMainScreen
};
/////////////////////
resource 'DLOG' (kSelectFrames, "Select Frames", purgeable) {
{40, 40, 288, 240},
rDocProc,
visible,
nogoAway,
0x0,
kSelectFrames,
"Select Frames",
centerMainScreen
};
resource 'DITL' (kSelectFrames, "Select Frames", purgeable) {
{ // Item Array:
/* [ 1] */ {208, 20, 228, 80}, Button {enabled , "OK#100" };
/* [ 2] */ {208, 120, 228, 180}, Button {enabled , "Cancel#101" };
/* [ 3] */ { 20, 20, 52, 52}, Icon {disabled, myIconRsrc2 };
/* [ 4] */ { 80, 20, 100, 70}, StaticText {disabled, "From:" };
/* [ 5] */ { 80, 90, 100, 140},
StaticText
{enabled , "@#1#9999" /* = overloaded CIntegerText field */ };
/* [ 6] */ {120, 20, 140, 70}, StaticText {disabled, "To:" };
/* [ 7] */ {120, 90, 140, 140}, StaticText {enabled , "@#1#9999" };
/* [ 8] */ {160, 25, 180, 175}, Button {enabled ,
"Select All (\0x11-A)#23" };
};
};
resource 'DLOG' (kGoToFrame, "Go To Frame", purgeable) {
{40, 40, 192, 240},
rDocProc,
visible,
nogoAway,
0x0,
kGoToFrame,
"Go To Frame",
centerMainScreen
};
resource 'DITL' (kGoToFrame, "Go To Frame", purgeable) {
{
/* [ 1] */ {112, 20, 132, 80}, Button {enabled , "OK#100" };
/* [ 2] */ {112, 120, 132, 180}, Button {enabled , "Cancel#101" };
/* [ 3] */ { 20, 20, 52, 52}, Icon {disabled, myIconRsrc2 };
/* [ 4] */ { 72, 75, 92, 125}, StaticText {enabled , "@#1#9999" };
};
};
include "Windoid"; // Special WDEF for Floating Windows.
#define kWindoid 104
/* MDEF "jmp" sequence(s) for various Menus. By convention, each MDEF ID
** matches the ID of the Menu being torn off. For this demo, we will
** tear-off ONLY one Menu and gBartender->IBartender will load it from
** my 'MBAR' resource. Note also that for the sake of consistency I have
** made the associated WIND ID(s) also match the MENU ID(s). After all,
** we could have more than one torn-off menu/window. */
#define kTearMenu 1000
#define kMDEF kTearMenu // Apple reserves 0 -> 127.
include "MDEFs";
/* ----- */
resource 'MENU' (kTearMenu, "1st Floating Tearoff Menu", purgeable) {
kTearMenu,
kTearMenu, // By TCL convention, MDEF ID = Menu ID.
0x7FFFFFFF,
enabled,
"Tear off this hummer !!!",
{
// Item(s) drawn “on-the-fly” by MDEF’s DrawMenu method.
}
};
resource 'WIND' (kTearMenu, "1st Floating Tearoff Menu", purgeable) {
{40, 40, 110, 112},
1668, // = 16*kWindoid + noGrowDocProc
invisible,
goAway,
0x0,
"",
noAutoCenter
};
resource 'hrct' (kTearMenu, "1st Floating Tearoff Menu", purgeable) {
HelpMgrVersion,
hmDefaultOptions,
0, /* balloon definition function */
0, /* variation code */
{
HMStringItem /* just one pane */
{
{ 0, 0 }, /* hot tip, set by the TCL */
{ 0, 0, 0, 0 }, /* ditto for the hot rect */
"This is my Tear-Off MENU. Double click "
"here and watch the spiffy fireworks!!!"
}
}
};
/////////////////////
#define kNotQuickTime 3003
resource 'DLOG' (kNotQuickTime, "Shame On You", purgeable) {
{30, 30, 300, 279}, /* EXACT same size as PICT */
altDBoxProc,
invisible,
nogoAway,
0x0, /* Refcon */
kNotQuickTime,
"", /* NO title for this type */
centerMainScreen
};
resource 'DITL' (kNotQuickTime, "Shame On You", purgeable) {
{
/* [ 1] */
{0, 0, 270, 249}, Picture {disabled, kNotQuickTime};
};
};
resource 'dctb' (kNotQuickTime, "Shame On You", purgeable) {
0x0, // wCSeed
0, // wCReserved
{
// Text color = color of window's title.
// Hilite color = color of horizontal lines, close box and
// grow box in title bar.
// Color of title bar = color around horizontal lines and
// the two boxes in the title bar.
//
// Please note that the ColorSpecs for wTextColor,
// wHiliteColor and wTitleBarColor are commented out
// because they do NOT apply to my particular DLOG!!
wContentColor, 65535, 65535, 65535; /* white */
wFrameColor, 65535, 0, 0; /* red */
// wTextColor, 65535, 65535, 65535; /* white */
// wHiliteColor, 65535, 65535, 65535; /* white */
// wTitleBarColor, 65535, 0, 0; /* red */
}
};
/////////////////////
#define mMovie 20
resource 'MBAR' (MBARapp, "MBAR", purgeable) {
{ /* array MenuArray: 4 elements */
/* [1] */
mApple,
/* [2] */
mFile,
/* [3] */
mEdit,
/* [4] */
mMovie,
/* [5] */
kTearMenu
}
};
resource 'MENU' (mApple, "Apple", purgeable) {
mApple,
textMenuProc,
0x7FFFFFFD,
enabled,
apple,
{
/* [ 1] */ "Read all about it, folks ...#256",
mySicn, "\0x1E", noMark, plain;
/* [ 2] */ "-", noIcon, noKey, noMark, plain;
}
};
/* ----- */
resource 'MENU' (mFile, "File", purgeable) {
// Where possible, use the standard Command Numbers provided by the TCL:
mFile,
textMenuProc,
0x7FFFF5ED,
enabled,
"File",
{
/* [ 1] */ "Making Progress ...#1024" , noIcon , noKey, noMark, bold ;
/* [ 2] */ "-" , noIcon , noKey, noMark, plain ;
/* [ 3] */ "New Movie#2" , noIcon , "N" , noMark, plain ;
/* [ 4] */ "Let the cameras roll ...#3" , myIcon2, "O" , noMark, italic+bold;
/* [ 5] */ "-" , noIcon , noKey, noMark, plain ;
/* [ 6] */ "Close Movie#4" , noIcon , "W" , noMark, plain ;
/* [ 7] */ "Save Movie#5" , noIcon , "S" , noMark, plain ;
/* [ 8] */ "Save Movie As...#6" , noIcon , noKey, noMark, plain ;
/* [ 9] */ "Revert to Saved Movie#7" , noIcon , "`" , noMark, plain ;
/* [10] */ "-" , noIcon , noKey, noMark, plain ;
/* [11] */ "Delete Movie ...#1025" , noIcon , "D" , noMark, bold ;
/* [12] */ "-" , noIcon , noKey, noMark, plain ;
/* [13] */ "Quit#1" , myIcon , "Q" , noMark, italic ;
}
};
/* ----- */
resource 'MENU' (mEdit, "Edit", purgeable) {
mEdit,
textMenuProc,
0x7FFFFFBD,
enabled,
"Edit",
{
/* [ 1] */ "Nothing to Undo#16" , noIcon, "Z" , noMark, plain ;
/* [ 2] */ "-" , noIcon, noKey, noMark, plain ;
/* [ 3] */ "Nothing to Cut#18" , noIcon, "X" , noMark, plain ;
/* [ 4] */ "Nothing to Copy#19" , noIcon, "C" , noMark, plain ;
/* [ 5] */ "Nothing to Paste#20", noIcon, "V" , noMark, plain ;
/* [ 6] */ "Nothing to Clear#21", noIcon, noKey, noMark, plain ;
/* [ 7] */ "-" , noIcon, noKey, noMark, plain ;
/* [ 8] */ "Show Clipboard#22" , noIcon, noKey, noMark, italic;
}
};
/* ----- */
resource 'MENU' (mMovie, "Movie", purgeable) {
mMovie,
textMenuProc,
0x7FFFFFDB,
enabled,
"Movie",
{
/* [ 1] */ "Play Movie Forward#1026" , noIcon, noKey, noMark, plain;
/* [ 2] */ "Play Movie Backward#1027" , noIcon, noKey, noMark, plain;
/* [ 3] */ "-" , noIcon, noKey, noMark, plain;
/* [ 4] */ "Go to Beginning of Movie#1028", noIcon, noKey, noMark, plain;
/* [ 5] */ "Go to End of Movie#1029" , noIcon, noKey, noMark, plain;
/* [ 6] */ "-" , noIcon, noKey, noMark, plain;
/* [ 7] */ "Go to Frame Number ...#1030" , noIcon, noKey, noMark, plain;
/* [ 8] */ "Select Frames ...#1031" , noIcon, noKey, noMark, plain;
/* [ 9] */ "Deselect Frames#1032" , noIcon, noKey, noMark, plain;
}
};
///////////////////// Balloon Help goodies ... /////////////////////
resource 'hfdr' (kHMHelpID, "Finder help", purgeable) {
HelpMgrVersion,
hmDefaultOptions,
0, /* balloon definition function */
0, /* variation code */
{ /* HFdrArrays ... */
HMPictItem {
999 // Picture Resource ID
// "Ain’t he cute?!*!?\n"
// " Courtesy of:\n"
// "I•A•C•S Software",
};
};
};
/*--------*/
resource 'hmnu' (kHMHelpMenuID, "my Help Menu item", purgeable) {
HelpMgrVersion,
hmDefaultOptions,
0, /* balloon definition function */
0, /* variation code */
HMSkipItem {
/* no missing items */
},
/* NO Menu Title items for this special case. */
/* The Help Manager processes Balloons for */
/* all the standard Help Menu items. */
{ /* my added item */
HMStringItem {
"Watch the spiffy fireworks !!!", /* enabled */
"Item is dimmed.",
"Item is checked.",
"" /* Item canNOT be otherwise marked. */
};
}; /* End of Menu Title + items */
};
/*--------*/
#define kRemoteHelp 5000
/* The TCL sets the hotRect to the icon's frame rectangle and
** the hotTip to the center point in the hotRect. The TCL
** figures out the hotRect because you pass the topLeft of the
** CIconPane to IIconPane when you initialize the object.
** So, there's NO need to figure out the arithmetic for each
** help item. However, I have provided a few examples below
** just for the sake of illustration. */
#define remoteHotTip {0, 0}
#define remoteHotRect {0, 0, 0, 0}
resource 'hrct' (kRemoteHelp, "Smart Remote", purgeable) {
HelpMgrVersion,
hmDefaultOptions,
0, /* balloon definition function */
0, /* variation code */
{
HMStringItem /* 1 - light */
{
{ 34, 21 }, /* hot tip, set by the TCL */
{ 18, 5, 50, 37 }, /* ditto for hot rect */
"Lights up when you press on one of the other Buttons"
},
HMStringItem /* 2 - eject */
{
{ 34, 57 },
{ 18, 41, 50, 73 },
"Click here to close the Movie"
},
HMStringItem /* 3 - load */
{
{ 34, 93 },
{ 18, 77, 50, 109 },
"Click here to open a Movie"
},
HMStringItem /* 4 - power */
{
{ 34, 129 },
{ 18, 113, 50, 145 },
"Click here to quit “Feature Movie”"
},
HMStringItem /* 5 - pause */
{
remoteHotTip,
remoteHotRect, // topLeft = {80, 33}
"Click here to pause the Movie. "
"Bell rings if you’re already paused."
},
HMStringItem /* 6 - stop */
{
remoteHotTip,
remoteHotRect, // topLeft = {80, 85}
"Click here to stop the Movie. "
"Bell rings if you’re stopped already."
},
HMStringItem /* 7 - play backward */
{
remoteHotTip,
remoteHotRect, // topLeft = {132, 33}
"Click here to play the Movie backward, starting at the end"
},
HMStringItem /* 8 - play forward */
{
remoteHotTip,
remoteHotRect, // topLeft = {132, 85}
"Click here to play the Movie forward, starting at the beginning"
},
HMStringItem /* 9 - go to beginning */
{
remoteHotTip,
remoteHotRect, // topLeft = {184, 5}
"Click here to go to the beginning of the Movie. "
"Bell rings if you’re already at the beginning."
},
HMStringItem /* 10 - step backward */
{
remoteHotTip,
remoteHotRect, // topLeft = {184, 41}
"Click here to step backward until you release the Mouse. "
"Bell rings when you reach the beginning of the Movie."
},
HMStringItem /* 11 - step forward */
{
remoteHotTip,
remoteHotRect, // topLeft = {184, 77}
"Click here to step forward until you release the Mouse. "
"Bell rings when you reach the end of the Movie."
},
HMStringItem /* 12 - go to end */
{
remoteHotTip,
remoteHotRect, // topLeft = {184, 113}
"Click here to go to the end of the Movie. "
"Bell rings if you’re already at the end."
},
HMStringItem /* 13 - volume down */
{
remoteHotTip,
remoteHotRect, // topLeft = {236, 33}
"Click here to turn the volume down until you release the Mouse. "
"Bell rings if the Movie has no sound or "
"when you turn the Movie’s volume totally off."
},
HMStringItem /* 14 - volume up */
{
remoteHotTip,
remoteHotRect, // topLeft = {236, 85}
"Click here to turn the volume up until you release the Mouse. "
"Bell rings if the Movie has no sound or "
"when you reach the Movie’s maximum volume."
},
/*
HMStringItem // 15 - QuickTime cicn
{
remoteHotTip,
remoteHotRect, // topLeft = {288, 59}
"This sub-Pane does NOT receive clicks "
"and, therefore, shows NO Balloon."
},
*/
HMStringItem /* itsMainPane */
{
remoteHotTip,
remoteHotRect, // topLeft = {0, 0}
"Thanks to the pioneering work of Edgar Lee "
"from Macintosh Developer Technical Support"
}
} /* end of array of items */
}; /* end of remote's 'hrct' resource */
///////////////////// QuickTime goodies ... /////////////////////
/* If an error occurs, call:
**
** FailOSErr(err);
**
** which then calls:
**
** Failure(err, message = 0);
**
** which via your TRY-CATCH-ENDTRY Macros propagates the error
** up to the TRY-CATCH-ENDTRY Handler within CApplication::Run().
** The latter's CATCH Handler will call:
**
** if (gLastError != kSilentErr)
** ErrorAlert( gLastError, gLastMessage);
**
** and then RETRY what you have in your TRY Handler. Because
** FailOSErr passed a message = 0 to Failure, ErrorAlert will
** look for a 'Estr' resource with an ID = the passed error. */
resource 'Estr' (-2000, "Movie Toolbox Error", purgeable) {
"couldNotResolveDataRef"
};
resource 'Estr' (-2001, "Movie Toolbox Error", purgeable) {
"badImageDescription"
};
resource 'Estr' (-2002, "Movie Toolbox Error", purgeable) {
"badPublicMovieAtom"
};
resource 'Estr' (-2003, "Movie Toolbox Error", purgeable) {
"cantFindHandler"
};
resource 'Estr' (-2004, "Movie Toolbox Error", purgeable) {
"cantOpenHandler"
};
resource 'Estr' (-2005, "Movie Toolbox Error", purgeable) {
"badComponentType"
};
resource 'Estr' (-2006, "Movie Toolbox Error", purgeable) {
"noMediaHandler"
};
resource 'Estr' (-2007, "Movie Toolbox Error", purgeable) {
"noDataHandler"
};
resource 'Estr' (-2008, "Movie Toolbox Error", purgeable) {
"invalidMedia"
};
resource 'Estr' (-2009, "Movie Toolbox Error", purgeable) {
"invalidTrack"
};
resource 'Estr' (-2010, "Movie Toolbox Error", purgeable) {
"invalidMovie"
};
resource 'Estr' (-2011, "Movie Toolbox Error", purgeable) {
"invalidSampleTable"
};
resource 'Estr' (-2012, "Movie Toolbox Error", purgeable) {
"invalidDataRef"
};
resource 'Estr' (-2013, "Movie Toolbox Error", purgeable) {
"invalidHandler"
};
resource 'Estr' (-2014, "Movie Toolbox Error", purgeable) {
"invalidDuration"
};
resource 'Estr' (-2015, "Movie Toolbox Error", purgeable) {
"invalidTime"
};
resource 'Estr' (-2016, "Movie Toolbox Error", purgeable) {
"cantPutPublicMovieAtom"
};
resource 'Estr' (-2017, "Movie Toolbox Error", purgeable) {
"badEditList"
};
resource 'Estr' (-2018, "Movie Toolbox Error", purgeable) {
"mediaTypesDontMatch"
};
resource 'Estr' (-2019, "Movie Toolbox Error", purgeable) {
"progressProcAborted"
};
resource 'Estr' (-2020, "Movie Toolbox Error", purgeable) {
"movieToolboxUnitialized"
};
resource 'Estr' (-2021, "Movie Toolbox Error", purgeable) {
"wfFileNotFound"
};
resource 'Estr' (-2022, "Movie Toolbox Error", purgeable) {
"cantCreateSingleForkFile"
};
resource 'Estr' (-2023, "Movie Toolbox Error", purgeable) {
"invalidEditState"
};
resource 'Estr' (-2024, "Movie Toolbox Error", purgeable) {
"nonMatchingEditState"
};
resource 'Estr' (-2025, "Movie Toolbox Error", purgeable) {
"staleEditState"
};
resource 'Estr' (-2026, "Movie Toolbox Error", purgeable) {
"userDataItemNotFound"
};
resource 'Estr' (-2027, "Movie Toolbox Error", purgeable) {
"maxSizeToGrowTooSmall"
};
resource 'Estr' (-2028, "Movie Toolbox Error", purgeable) {
"badTrackIndex"
};
resource 'Estr' (-2029, "Movie Toolbox Error", purgeable) {
"trackIDNotFound"
};
resource 'Estr' (-2030, "Movie Toolbox Error", purgeable) {
"trackNotInMovie"
};
resource 'Estr' (-2031, "Movie Toolbox Error", purgeable) {
"timeNotInTrack"
};
resource 'Estr' (-2032, "Movie Toolbox Error", purgeable) {
"timeNotInMedia"
};
resource 'Estr' (-2033, "Movie Toolbox Error", purgeable) {
"badEditIndex"
};
resource 'Estr' (-2034, "Movie Toolbox Error", purgeable) {
"internalQuickTimeError"
};
resource 'Estr' (-2035, "Movie Toolbox Error", purgeable) {
"cantEnableTrack"
};
resource 'Estr' (-2036, "Movie Toolbox Error", purgeable) {
"invalidRect"
};
resource 'Estr' (-2037, "Movie Toolbox Error", purgeable) {
"invalidSampleNum"
};
resource 'Estr' (-2038, "Movie Toolbox Error", purgeable) {
"invalidChunkNum"
};
resource 'Estr' (-2039, "Movie Toolbox Error", purgeable) {
"invalidSampleDescIndex"
};
resource 'Estr' (-2040, "Movie Toolbox Error", purgeable) {
"invalidChunkCache"
};
resource 'Estr' (-2041, "Movie Toolbox Error", purgeable) {
"invalidSampleDescription"
};
resource 'Estr' (-2042, "Movie Toolbox Error", purgeable) {
"dataNotOpenForRead"
};
resource 'Estr' (-2043, "Movie Toolbox Error", purgeable) {
"dataNotOpenForWrite"
};
resource 'Estr' (-2044, "Movie Toolbox Error", purgeable) {
"dataAlreadyOpenForWrite"
};
resource 'Estr' (-2045, "Movie Toolbox Error", purgeable) {
"dataAlreadyClosed"
};
resource 'Estr' (-2046, "Movie Toolbox Error", purgeable) {
"endOfDataReached"
};
resource 'Estr' (-2047, "Movie Toolbox Error", purgeable) {
"dataNoDataRef"
};
resource 'Estr' (-2048, "Movie Toolbox Error", purgeable) {
"noMovieFound"
};
resource 'Estr' (-2049, "Movie Toolbox Error", purgeable) {
"invalidDataRefContainer"
};
resource 'Estr' (-2050, "Movie Toolbox Error", purgeable) {
"badDataRefIndex"
};
resource 'Estr' (-2051, "Movie Toolbox Error", purgeable) {
"noDefaultDataRef"
};
resource 'Estr' (-2052, "Movie Toolbox Error", purgeable) {
"couldNotUseAnExistingSample"
};
resource 'Estr' (-2053, "Movie Toolbox Error", purgeable) {
"featureUnsupported"
};
/* ---------- */
resource 'Estr' (-3000, "Component Manager Error", purgeable) {
"invalidComponentID"
};
resource 'Estr' (-3001, "Component Manager Error", purgeable) {
"validInstancesExist"
};
resource 'Estr' (-3002, "Component Manager Error", purgeable) {
"componentNotCaptured"
};
resource 'Estr' (-3003, "Component Manager Error", purgeable) {
"componentDontRegister"
};
/* ---------- */
resource 'Estr' (-9400, "QT Component Manager Error", purgeable) {
"noDeviceForChannel"
};
resource 'Estr' (-9401, "QT Component Manager Error", purgeable) {
"grabTimeComplete"
};
resource 'Estr' (-9402, "QT Component Manager Error", purgeable) {
"cantDoThatInCurrentMode"
};
resource 'Estr' (-9403, "QT Component Manager Error", purgeable) {
"notEnoughMemoryToGrab"
};
resource 'Estr' (-9404, "QT Component Manager Error", purgeable) {
"notEnoughDiskSpaceToGrab"
};
resource 'Estr' (-9405, "QT Component Manager Error", purgeable) {
"couldntGetRequiredComponent"
};
resource 'Estr' (-9406, "QT Component Manager Error", purgeable) {
"badSGChannel"
};
resource 'Estr' (-9407, "QT Component Manager Error", purgeable) {
"seqGrabInfoNotAvailable"
};
resource 'Estr' (-9408, "QT Component Manager Error", purgeable) {
"deviceCantMeetRequest"
};
/* ------------------
** BIG TIME problems:
** ------------------ */
#define kGeneralQuickTimeMemoryError -9999
resource 'Estr' (kGeneralQuickTimeMemoryError, "Memory Problems", purgeable) {
"of memory problems ... the Movie you’ve tried to open is "
"too large. Close an existing Movie OR choose another one."
};
///// My Undo/Redo Task Names /////
#define STRtaskNames 130
resource 'STR#' (STRtaskNames, "Task Names", purgeable) {
{
/* [ 1] */
"Revert to Saved Movie",
/* [ 2] */
"Cut Movie",
/* [ 3] */
"Copy Movie",
/* [ 4] */
"Paste Movie",
/* [ 5] */
"Clear Movie"
};
};